//
//  AppHelper.m
//  ZZmetro
//
//  Created by 一介布衣 on 2020/6/24.
//  Copyright © 2020 一介布衣. All rights reserved.
//

#import "AppHelper.h"
#import "WebViewController.h"

@implementation AppHelper

+ (NSString *) formatUrl:(NSString*) url {
    NSMutableString* str = [[NSMutableString alloc] init];
    [str appendString:BASE_URL];
    [str appendString:url];
    return str;
}

+ (void) enterH5Page:(NSString*) h5Url {
    UINavigationController *navCtl = [UIViewController currentNavigationController];
    WebViewController *web = [WebViewController new];
    NSString* url = [AppHelper formatUrl:h5Url];
    web.url = url;
    [navCtl pushViewController:web animated:YES];
}
@end
